#this is a comment.
#Name a variable:
#
my_name <- "Sarah"
my_cool_number <- 20My First Quarto
The title above will be rendered as a first-level header, so always start with the second level
Make sure that you give your markdown some room to breathe, with empty lines between sections and spaces after the heading and bullet indicators.
About me
Here are three things you might not know about me:
- Before I came to Cronkite, I’d never lived farther west than Western New York.
- I saw the Talking Heads play “Psycho Killer” at CBGB. (The drinking age was 18 then)
- The only sport I ever followed much was college basketball. I went to school at UNC and taught at Duke. Guess which one has my loyalty.
My favorite animal
A lot of times, images come into a markdown very large. There are ways to make it smaller. Here’s a picture of my favorite animal, downloaded from https://unsplash.com, with the width set to 6 inches.
Adding R code
So far, this is just a regular document – it doesn’t have anything special to R. But the reason that R Markdown is useful is that you can combine your program with your document. To add a “code chunk”, press CTL-Option/Alt-i at the same time, or go to the top and use the menu, “Insert” an R chunk. If you do that, you’ll notice that you have options for other computer languages. Don’t worry about that just yet.
Now you can print those variables:
my_name
my_cool_number[1] "Sarah"
[1] 20